Introduction

Column

Motivation

Carbon Emissions: Which nations are contributing the most to Climate Change?

With the annual reports of anthropogenic climate change being more dire, and that carbon emissions need to be reduced, I found it important to see who was contributing the most and whether those reductions were being met.

Some of the research questions for this project:

  1. Which nations have contributed the most to climate change in terms of CO2 emissions?

  2. What are the factors that have led to such high emission rates?

  3. Which nations, if any, have reduced their emissions?

Column

All of the data for this project was obtained from Our World in Data.

We will be looking at data between 1949 and 2019.

Variables in Dataset

The following are some of the variables:

  • Country

  • Year

  • Total Emissions

  • Trade Emissions

  • Consumption Emissions

  • Production Emissions

  • Emissions Per Capita

Modifications in R

The data from OWID begins in 1750 and only contains 223 countries. From 1949 onward, there are 224 countries included in the dataset.In order to have more consistency, the data files were modified to begin in 1949 so all emissions will be counted from there. The dataset also previously accounted for total emissions, but for the purposes of this analysis, the emissions data were modified to account for the average both per year and all-time.

Continental Emissions

Column

Over Time

Something

Something Else

Consumption

Column

Observations

We can see that, overtime, the emissions from South America and Africa has remained relatively the same. North America and Asia’s emissions have continued to climb. Europe was, up until the 1990s, the dominant emitter, but they have since begun to decline and are now only emitting more than South America and Africa. Thia ia a result of the timeframe restrictions, with our observations period only beginning in 1949 and continuing until 2019. Had we started in 1750 and continued until present day, we would likely see Europe being the primary emitter for a longer period of time. It is also likely that Europe’s total average emissions would be closer to, or greater than, either North American or Asia.

Average CO2 by Consumption

Average CO2 Emissions per Capita

Trade Emissions

Average CO2 Emissions per Country

---
title: "CO2 Emissions Dashboard"
author: "Anthony Lapham"
output: 
  flexdashboard::flex_dashboard:
    theme: paper
    orientation: columns
    social: ["linkedin"]
    source_code: embed
---

```{r setup, include=FALSE}
# if R package pacman is not installed, install it first 
if(require(pacman) == FALSE) install.packages('pacman') 

# load all necessary packages 
pacman::p_load(car, tidyverse, magrittr, RColorBrewer, ggsci, ggthemes, scales,  
               ggplot2, ggrepel,  
              DataExplorer, DT, conflicted, magick, forcats)

conflict_prefer("filter", "dplyr") 
 
library(flexdashboard)  ## you need this package to create dashboard

setwd("C:/Users/lapha/Box/Capstone Lapham/R Code")
```

Introduction
=======================================================================


Column {.tabset data-width=800} 
-----------------------------------------------------------------------

### Motivation


Carbon Emissions: Which nations are contributing the most to Climate Change?

With the annual reports of anthropogenic climate change being more dire, and that carbon emissions need to be reduced, I found it important to see who was contributing the most and whether those reductions were being met.

Some of the research questions for this project:

1. Which nations have contributed the most to climate change in terms of CO2 emissions?

2. What are the factors that have led to such high emission rates?

3. Which nations, if any, have reduced their emissions?




Column {.tabset data-width=800}
-----------------------------------------------------------------------


All of the data for this project was obtained from Our World in Data.

We will be looking at data between 1949 and 2019.



### Variables in Dataset


The following are some of the variables:

- Country

- Year

- Total Emissions

- Trade Emissions

- Consumption Emissions

- Production Emissions

- Emissions Per Capita




### Modifications in R 



The data from OWID begins in 1750 and only contains 223 countries. From 1949 onward, there are 224 countries included in the dataset.In order to have more consistency, the data files were modified to begin in 1949 so all emissions will be counted from there. The dataset also previously accounted for total emissions, but for the purposes of this analysis, the emissions data were modified to account for the average both per year and all-time.





Continental Emissions
=======================================================================

Column {.tabset data-width=500}
----------------------------------------------------------------------

### Over Time

### Something

### Something Else

### Consumption ```{r} # create a list of the files from your target directory file_list <- list.files(path="../Data", pattern="adjusted_") files <- vector("list", length(file_list)) for (i in 1:length(file_list)){ files[[i]] <- read_csv(paste0("../Data/", file_list[i])) } df1 <- do.call(rbind.data.frame, files[1]) consumption <- ggplot(data = df1, aes(x = reorder(Entity, +average_co2), y = average_co2)) + geom_bar(colour="blue",stat="identity") + ggtitle("Consumption Emissions") + xlab("Continent") + ylab("Average Co2") consumption ``` Column {data-wdith=500} ---------------------------------------------------------------------- ### Observations We can see that, overtime, the emissions from South America and Africa has remained relatively the same. North America and Asia's emissions have continued to climb. Europe was, up until the 1990s, the dominant emitter, but they have since begun to decline and are now only emitting more than South America and Africa. Thia ia a result of the timeframe restrictions, with our observations period only beginning in 1949 and continuing until 2019. Had we started in 1750 and continued until present day, we would likely see Europe being the primary emitter for a longer period of time. It is also likely that Europe's total average emissions would be closer to, or greater than, either North American or Asia. Average CO2 by Consumption ============================================================================

Average CO2 Emissions per Capita =======================================================================

Trade Emissions ======================================================================

Average CO2 Emissions per Country =======================================================================